<template>
  <!-- 人员管理--新增和编辑 -->
  <el-dialog title="合同内容"
             class="addPersonage"
             width='662px'
             :visible.sync="visible">
    <!-- 具体表单 -->
    <div class="box-card">
      <div class="contHtml"
           v-html="contractText">
      </div>
    </div>
  </el-dialog>
</template>

<script>
export default {
  data () {
    return {
      // 隐藏
      visible: false,
      // 数据
      id: '',
      contractText: ''
    }
  },
  methods: {
    // 父调用的方法
    init (id) {
      this.id = id || 0
      // console.log(id)
      this.visible = true
      this.$http({
        url: this.$http.adornUrl('/sys/contract/info/' + this.id),
        method: 'get',
        params: this.$http.adornParams()
      }).then(({ data }) => {
        this.contractText = data.sysContract.contractText
        // if (!data.personUser.bakInfo) {
        //   this.dataForm.bakInfo = {
        //     bankCardNumber: '',
        //     bankName: ''
        //   }
        // }
        // this.dataForm.status = this.dataForm.status + ''
        // this.dataForm.isAuth = this.dataForm.isAuth + ''
      })
    }
    // 结束
  }
}
</script>

<style lang="scss">
.addPersonage {
  .el-dialog {
    min-height: 500px;
  }
  .forms {
    .el-input.el-input--medium {
      width: 370px;
    }
    .el-dialog__header {
      background-color: #f8f8f8;
    }
    .el-dialog__body {
      display: flex;
      justify-content: center;
    }
    .btn {
      width: 370px;
    }
    .dialog-footer {
      text-align: center !important;
      padding-bottom: 39px;
    }
    .el-dialog__footer {
      text-align: center;
      padding-bottom: 39px;
    }
  }
  .box-card {
    padding: 0 20px;
    width: 100%;
    .text {
      font-size: 14px;
    }

    .item {
      padding: 0 0 18px 0;
      margin-bottom: 18px;
      border-bottom: 1px solid #f1f3f8;
      span {
        display: inline-block;
        width: 100px;
        font-size: 16px;
        font-family: Microsoft YaHei;
        font-weight: 400;
        line-height: 21px;
        color: #000000;
      }
      .license_img {
        display: inline-block;
        width: 50px;
        height: 50px;
        border-radius: 50%;
        border: 1px solid #d9d9d9;
      }
    }
  }
}
</style>
